// 引入mongoose
const mongoose = require("mongoose");

// 修改放映厅信息
const updateOne = async (_id) => {
    const seatingsModel = mongoose.model("seatings");
    // 更新修改信息
    await seatingsModel.updateOne({  _id  },{status:1})
    const result = await seatingsModel.findOne({ _id })
    console.log(result);
    if(result.status==1){
        const status = { status: true };
        return status;
    }else{
        const status = { status: false };
        return status;
    }
}
// 暴露方法接口
module.exports = { updateOne };